/**
 * 获取权限列表
 */
import request from '@/utils/request'
export function getPermission(params) {
  return request({
    url: '/roles',
    method: 'get',
    params
  })
}

/**
*删除角色 
*/
export function delJueSe(params) {
  return request({
    url: `/roles/${params.id}`,
    method: 'delete',
  })
}
/**
*修改权限
*/
export function putRights(date) {
  return request({
    url: `/roles/${date.id}`,
    method: 'patch',
    data: {
      rights: date.rights
    }
  })
}